package com.ojoin.trade.supplyloan_core.constdef;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

import com.ojoin.trade.supplyloan_core.web.domain.TbSlPlatformInfo;


/**
 * 电商平台名称及访问地址数据常量
 * @author guoting
 *
 */

public class IPlatformUrlDef {
	/**
	 * 天猫保证登陆的心跳请求urls
	 */
	 
	public static enum Statues {
		inited("申请加入", "inited"), enabled("正常抓取", "enabled"),
		//nameError("账号名称不匹配", "nameError"),accountError("结算账号不匹配", "accountError"), 
		paused("申请暂停", "paused"),disabled("已暂停", "disabled"); 
        // 成员变量
        private String name;
        private String index;

        // 构造方法
        private Statues(String name, String index) {
            this.name = name;
            this.index = index;
        }

        // 普通方法
        public static String getName(String index) {
            for (Statues c : Statues.values()) {
                if (c.getIndex().equals(index)) {
                    return c.name;
                }
            } 
            return null;
        }

        // get set 方法
        public String getName() {
            return name;
        }

        public void setName(String name) {
            this.name = name;
        }

        public String getIndex() {
            return index;
        }
 
        public void setIndex(String index) {
            this.index = index;
        }
    }
	
	
	public final static Map<String,List<String>> mapUrl = new HashMap<String,List<String>>();
	
	static { 
		
        List<String> CainiaoUrls = new ArrayList<String>();
		
        CainiaoUrls.add("http://dip.work.cainiao.com/inventory/scItemQuery.htm");
        CainiaoUrls.add("http://dip.work.cainiao.com/inventory/scItemQuery.htm");
		 
		mapUrl.put(TbSlPlatformInfo.THIRDSELLER_CAINIAO, CainiaoUrls);
		mapUrl.put(TbSlPlatformInfo.SUPPLIER_CAINIAO, CainiaoUrls);
		
		
		List<String> TMALLUrls = new ArrayList<String>();
		
		//TMALLUrls.add("http://work.cbbs.tmall.com//count/countMessageGroupByModule.json");
		//TMALLUrls.add("http://work.cbbs.tmall.com//count/countJobGroupByModule.json");
		//TMALLUrls.add("http://work.cbbs.tmall.com//count/countCertOrder.json");
		//TMALLUrls.add("http://work.cbbs.tmall.com//count/countStockOut.json");
		//TMALLUrls.add("http://work.cbbs.tmall.com//count/countSupplierDeliveredOrders.json");
		TMALLUrls.add("http://supplier.cbbs.tmall.com/supplier/news/financingList.htm");
		
		mapUrl.put(TbSlPlatformInfo.SUPPLIER_TMALL, TMALLUrls);
		
        List<String> tTmall = new ArrayList<String>();
		
        tTmall.add("https://zizhanghao.taobao.com/subaccount/index.htm");
        tTmall.add("https://zizhanghao.taobao.com/subaccount/monitor/chatRecordQuery.htm");
        tTmall.add("https://rate.taobao.com/myRate.htm");
		
		mapUrl.put(TbSlPlatformInfo.THIRDSELLER_TMALL, tTmall);
		 
		
		 List<String> alipay = new ArrayList<String>();
			
		 alipay.add("https://uemprod.alipay.com/user/ihome.htm");
		 alipay.add("https://uemprod.alipay.com/user/bankAccountIndex.htm");
		 alipay.add("https://uemprod.alipay.com/user/account/index.htm");
		 alipay.add("https://uemprod.alipay.com/user/associatedAccount/admin.htm");
		 
		mapUrl.put(TbSlPlatformInfo.ALIPAY, alipay);
		
	
		List<String> SuNingUrls = new ArrayList<String>();
		SuNingUrls.add("http://scs.suning.com/sps/portal/showPortalPage.action");
		SuNingUrls.add("http://scs.suning.com/sps/BadMachineReport/queryBadMachineReport.action");
		SuNingUrls.add("http://scs.suning.com/sps/bizConsulting/queryAllGroup.action");
		
		mapUrl.put(TbSlPlatformInfo.SUPPLIER_SUNING, SuNingUrls);
		mapUrl.put(TbSlPlatformInfo.THIRDSELLER_SUNING, SuNingUrls);
		
		
		List<String> sfbestUrls = new ArrayList<String>();
		sfbestUrls.add("http://supplier.sfbest.cn/settlement/index/");
		sfbestUrls.add("http://supplier.sfbest.cn/invoiceBatch/index/");
		sfbestUrls.add("http://supplier.sfbest.cn/purchaseOrder/finish/");
		sfbestUrls.add("http://supplier.sfbest.cn/purchaseOrder/loadIndex/type/finish");
		sfbestUrls.add("http://supplier.sfbest.cn/purchaseOrder/loadIndex/type/finish");
		sfbestUrls.add("http://supplier.sfbest.cn/product/index");
		
		mapUrl.put(TbSlPlatformInfo.SUPPLIER_SFBEST, sfbestUrls);
		
		List<String> yhdUrls = new ArrayList<String>();
		yhdUrls.add("http://supplier.yhd.com/fbycontract/contractList.action");
		yhdUrls.add("http://supplier.yhd.com/supplierfinancial/showAccountsList.action");
		yhdUrls.add("http://supplier.yhd.com/fbySupplier/supplierInfo.action");
		yhdUrls.add("http://supplier.yhd.com/fbyProductSale/findProductChargeInfo.action");
		yhdUrls.add("http://supplier.yhd.com/fbyProduct/productManager.action");
		yhdUrls.add("http://supplier.yhd.com/fbyProduct/searchNewCommodity.action");
		
		
		mapUrl.put(TbSlPlatformInfo.SUPPLIER_YHD, yhdUrls);
		
		List<String> amazonUrls = new ArrayList<String>();
		amazonUrls.add("https://vendorcentral.amazon.cn/st/vendor/members/itemmanagementapp/addmultiple");
		amazonUrls.add("https://vendorcentral.amazon.cn/st/vendor/members/itemmanagementapp/parenttasksubhistory");
		amazonUrls.add("https://vendorcentral.amazon.cn/st/vendor/members/ap/otp");
		amazonUrls.add("https://vendorcentral.amazon.cn/gp/vendor/members/user-permission/user-permission");
		amazonUrls.add("https://vendorcentral.amazon.cn/gp/vendor/members/admin/home");
		amazonUrls.add("https://vendorcentral.amazon.cn/gp/vendor/members/vsw/home");
		
		
		mapUrl.put(TbSlPlatformInfo.SUPPLIER_AMAZON, amazonUrls);
		
		
		List<String> thrirdUrls = new ArrayList<String>();
		thrirdUrls.add("https://shop.jd.com/index.action");
		thrirdUrls.add("https://ware.shop.jd.com/onSaleWare/onSaleWare_newDoSearch.action?firstQuery=1");

		
		
		mapUrl.put(TbSlPlatformInfo.THIRDSELLER_JD, thrirdUrls);
		
	} 
	
	
	 
}
